load("//bazel:api.bzl", "mojo_filecheck_test", "mojo_test")

package(default_visibility = ["//visibility:private"])

_FILECHECK_TESTS = [
    "test_dimlist.mojo",
    "test_naive_matmul.mojo",
    "test_ndbuffer.mojo",
    "test_ndbuffer_dynamic_shape.mojo",
    "test_ndbuffer_dynamic_stride.mojo",
    "test_ndbuffer_indexing.mojo",
    "test_partial_load_store.mojo",
    "test_strsv.mojo",
]

[
    mojo_filecheck_test(
        name = src + ".test",
        srcs = [src],
        copts = [
            "--debug-level",
            "full",
        ],
        deps = [
            "//max:internal_utils",
            "@mojo//:stdlib",
            "@mojo//:test_utils",
        ],
    )
    for src in _FILECHECK_TESTS
]

[
    mojo_test(
        name = src + ".test",
        srcs = [src],
        copts = [
            "--debug-level",
            "full",
        ],
        deps = [
            "//max:internal_utils",
            "@mojo//:stdlib",
            "@mojo//:test_utils",
        ],
    )
    for src in glob(
        ["*.mojo"],
        allow_empty = True,  # No non-FileCheck tests yet
        exclude = _FILECHECK_TESTS,
    )
]
